﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ZR.Model.Models.ProductionControl
{
    /// <summary>
    /// 工位配置表
    /// </summary>
    [SugarTable("workstation_config")]
    public class WorkstationConfig : BaseEntity
    {
        /// <summary>
        /// Id
        /// </summary>
        [SugarColumn(IsPrimaryKey = true, IsIdentity = false)]
        public int Id { get; set; }

        /// <summary>
        /// 产线代号
        /// </summary>
        [SugarColumn(ColumnName = "production_line_code")]
        public string ProductionLineCode { get; set; }

        /// <summary>
        /// 上位机代号
        /// </summary>
        [SugarColumn(ColumnName = "hmi_code")]
        public string HmiCode { get; set; }

        /// <summary>
        /// 工位代号
        /// </summary>
        [SugarColumn(ColumnName = "workstation_code")]
        public string WorkstationCode { get; set; }

        /// <summary>
        /// 工位名称
        /// </summary>
        [SugarColumn(ColumnName = "workstation_name")]
        public string WorkstationName { get; set; }

        /// <summary>
        /// PLC启用
        /// </summary>
        [SugarColumn(ColumnName = "plc_enabled")]
        public int PlcEnabled { get; set; }

        /// <summary>
        /// 扫码枪启用
        /// </summary>
        [SugarColumn(ColumnName = "scanner_enabled")]
        public int ScannerEnabled { get; set; }

        /// <summary>
        /// CCD启用
        /// </summary>
        [SugarColumn(ColumnName = "ccd_enabled")]
        public int CcdEnabled { get; set; }

        /// <summary>
        /// 打印机启用
        /// </summary>
        [SugarColumn(ColumnName = "printer_enabled")]
        public int PrinterEnabled { get; set; }

        /// <summary>
        /// 打标机启用
        /// </summary>
        [SugarColumn(ColumnName = "marking_machine_enabled")]
        public int MarkingMachineEnabled { get; set; }

        /// <summary>
        /// 物料校验启用
        /// </summary>
        [SugarColumn(ColumnName = "material_verification_enabled")]
        public bool MaterialVerificationEnabled { get; set; }

        /// <summary>
        /// 公差带校验启用
        /// </summary>
        [SugarColumn(ColumnName = "tolerance_verification_enabled")]
        public int ToleranceVerificationEnabled { get; set; }

        /// <summary>
        /// 工位验证启用
        /// </summary>
        [SugarColumn(ColumnName = "station_verify_enabled")]
        public int StationVerifyEnabled { get; set; }

        /// <summary>
        /// 创建时间
        /// </summary>
        [SugarColumn(ColumnName = "creation_time")]
        public DateTime? CreationTime { get; set; }

        /// <summary>
        /// 创建人
        /// </summary>
        [SugarColumn(ColumnName = "creator_name")]
        public string CreatorName { get; set; }
    }
}